﻿using System;
using System.ComponentModel.DataAnnotations.Schema;

namespace community.Models
{
    // 居委会
    public class Committee
    {
        [DatabaseGenerated(DatabaseGeneratedOption.Identity)] // 告诉 EF：这是数据库生成的
        public int Id { get; set; }
        public string Name { get; set; } // 居委会名称
        public string Description { get; set; } // 居委会描述
        public string Address { get; set; } // 居委会地址
        public string ContactPhone { get; set; } // 联系电话
        public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
        public DateTime UpdatedAt { get; set; } = DateTime.UtcNow;

        // 导航属性
        public virtual ICollection<Complex> Complexes { get; set; } = new List<Complex>();
    }
}
